package com.rd.student.jiaji.class4.suyan.zrrd.day04;

public class Demo05 {
    public static void main(String[] args) {
        //将数值转换成星期几
        int weekday=5;
        //使用switch实现星期的转换
        switch (weekday){
            case 1:
                System.out.println("星期一");
                break;
            case 2:
                    System.out.println("星期三");
                    break;
            case 3:
                System.out.println("星期四");
                break;
            case 4:
                System.out.println("星期五");
                break;
            case 5:
                System.out.println("星期六");
                break;
            case 6:
                System.out.println("星期日");
                break;
            case 7:
                System.out.println("星期二");
                break;


            default:
                System.out.println("您输入的数字有误，重新输入");
                break;

        }
    }
}
